package jnBase.user
{
	

	/**用户信息*/
	public class User
	{
		private  var _UserId:String;
		private  var _RealName:String;
		private  var _ClassName:String;
		private  var _Email:String;
		/**
		 *头像 
		 */		
		private var _HeadIcon:String;
		/**用户类型*/
		public   var UserType:String="";
		/**老师*/
		public static const UserType_Teacher:String="isTeacher";
		/**学生*/
		public static const UserType_Student:String="isStudent";
		/**超级管理员**/
		public  static const UserType_Manager:String="isManager";
		/**访客*/
		public  static const UserType_Customer:String="isCustomer";
		public function User($userData:Object)
		{
			_UserId=$userData.userid;
			_RealName=$userData.username;
			_ClassName=$userData.classnames;
			_Email=$userData.email;
			_HeadIcon=$userData.headicon;
			UserType=$userData.usertype;
			/*switch($userData.UserType)
			{
				case 0:{UserType=User.UserType_Manager;break;}
				case 1:{UserType=User.UserType_Student;break;}
				case 2:{UserType=User.UserType_Teacher;break;}
				case 3:{UserType=User.UserType_Customer;break;}
				default:
				{
					break;
				}
			}*/
		}
		/**用户id*/
		public   function get UserId():String
		{
			return _UserId;
		}

		/**昵称**/
		public   function get RealName():String
		{
			return _RealName;
		}


		/**班级名称*/
		public  function get ClassName():String
		{
			return _ClassName;
		}

		/**邮箱*/
		public   function get Email():String
		{
			return _Email;
		}

		public function get HeadIcon():String
		{
			return _HeadIcon;
		}



	}
}